if (this._state !== State.SCROLLING)
return;
- if (this.orientation === Clutter.Orientation.HORIZONTAL &&
- Clutter.get_default_text_direction() === Clutter.TextDirection.RTL)
- delta = -delta;
-
this._progress += delta / distance;
this._progress = Math.clamp(this._progress, ...this._getBounds(this._initialProgress));
_updatePanGesture(panGesture) {
const deltaVec = panGesture.get_delta_abs();
const delta = this.orientation === Clutter.Orientation.HORIZONTAL
- ? -deltaVec.get_x()
- : -deltaVec.get_y();
+ ? this._getGestureDirFactor() * deltaVec.get_x()
+ : this._getGestureDirFactor() * deltaVec.get_y();
this._updateGesture(delta, this._distance);
}
return;
}
+ if (this.orientation === Clutter.Orientation.HORIZONTAL &&
+ Clutter.get_default_text_direction() === Clutter.TextDirection.RTL)
+ delta = -delta;
+
this._history.append(time, delta);
this._updateGesture(delta, distance);
}